import requests

def GetPassage(url):
    headers = {
        "User-Agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 11_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E302 SearchCraft/2.6.1 (Baidu; P2 11.3.1)"
    }

    response = requests.get(url, headers=headers)

# 检查请求是否成功
    if response.status_code == 200:
        print("请求成功！")
        print("响应内容长度:", len(response.text))
        # 如果需要查看响应内容，可以取消下面的注释
        import readpassage
        readpassage.extract_first_js_decode(response.text)
    else:
        print(f"请求失败，状态码: {response.status_code}")
